package com.ly.datacenter.crud.json;

/**
 * function:
 * 
 * @author watson email: watson.wu@hotmail.com
 * @date 2009-9-2
 */
public class FieldAttributeMetadata {

	private boolean nullable;
	private boolean displayable;
	private boolean indexable;
	private boolean pk;
	private boolean searchable;
	private boolean signed;
	private String comment;
	private String defval;//default value
	private String label;
	private int length;//total length for storing
	private String css;
	private String range;//defined for options field
	private String html;//define all HTML directly
	private String type;//more detail defined, eg. radio
//	private int width;

	public FieldAttributeMetadata() {
		super();
	}

	public FieldAttributeMetadata(boolean nullable, boolean displayable,
			boolean indexable, boolean pk, boolean searchable, boolean signed,
			String comment, String defval, String label, int length, String css, String range, String html, String type) {
		super();
		this.nullable = nullable;
		this.displayable = displayable;
		this.indexable = indexable;
		this.pk = pk;
		this.searchable = searchable;
		this.signed = signed;
		this.comment = comment;
		this.defval = defval;
		this.label = label;
		this.length = length;
		this.css = css;
		this.range = range;
		this.html = html;
		this.type = type;
	}

	public boolean isNullable() {
		return nullable;
	}

	public void setNullable(boolean nullable) {
		this.nullable = nullable;
	}

	public boolean isDisplayable() {
		return displayable;
	}

	public void setDisplayable(boolean displayable) {
		this.displayable = displayable;
	}

	public boolean isIndexable() {
		return indexable;
	}

	public void setIndexable(boolean indexable) {
		this.indexable = indexable;
	}

	public boolean isPk() {
		return pk;
	}

	public void setPk(boolean pk) {
		this.pk = pk;
	}

	public boolean isSearchable() {
		return searchable;
	}

	public void setSearchable(boolean searchable) {
		this.searchable = searchable;
	}

	public boolean isSigned() {
		return signed;
	}

	public void setSigned(boolean signed) {
		this.signed = signed;
	}

	public String getComment() {
		return comment;
	}

	public void setComment(String comment) {
		this.comment = comment;
	}

	public String getDefval() {
		return defval;
	}

	public void setDefval(String defval) {
		this.defval = defval;
	}

	public String getLabel() {
		return label;
	}

	public void setLabel(String label) {
		this.label = label;
	}

	public int getLength() {
		return length;
	}

	public void setLength(int length) {
		this.length = length;
	}

	public String getCss() {
		return css;
	}

	public void setCss(String css) {
		this.css = css;
	}

	public String getRange() {
		return range;
	}

	public void setRange(String range) {
		this.range = range;
	}

	public String getHtml() {
		return html;
	}

	public void setHtml(String html) {
		this.html = html;
	}

	public String getType() {
		return type;
	}

	public void setType(String type) {
		this.type = type;
	}

}
